package cn.jlkj22.csmallproductteachers.controller;

import cn.jlkj22.csmallproductteachers.pojo.dto.AlbumAddNewDTO;
import cn.jlkj22.csmallproductteachers.service.IAlbumService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/album")
public class AlbumController {
    @Autowired
    private IAlbumService albumService;
    //http://localhost:8080/doc.html
    // http://localhost:8080/album/add-new?name=TestAlbum001&description=TestDescription001&sort=66
    @RequestMapping("/add-new")
    public void addNew(AlbumAddNewDTO albumAddNewDTO){
        albumService.addNew(albumAddNewDTO);
    }
}
